package com.loong.member.service.impl;

import com.loong.common.dubbo.service.AbstractService;
import com.loong.common.rest.rpc.RPCResponse;
import com.loong.data.service.IShopService;
import com.loong.member.dto.MemberAddressDTOResult;
import com.loong.member.handler.MemberAddressHandler;
import com.loong.member.service.IMemberAddressService;
import org.apache.dubbo.config.annotation.DubboService;

import javax.annotation.Resource;

/**
 * @Description:
 * @Author: LiuQun
 * @Date: 2021/1/4 15:46
 */
@DubboService(timeout = 5000,interfaceClass = IMemberAddressService.class)
public class MemberAddressServiceImpl extends AbstractService implements IMemberAddressService {

    @Resource
    private MemberAddressHandler addressHandler;

    @Override
    public RPCResponse<MemberAddressDTOResult> findMemberAddressById(Long addressId) {
        return serviceExecutor.execute(() -> addressHandler.findMemberAddressById(addressId));
    }
}
